import { combineReducers } from 'redux'
import { routerReducer } from 'react-router-redux';

import appReducer from '@/apps/reducer'
import personReducer from '@/personal/reducer'
import suggestReducer from '@/suggestion/reducer'
import loginReducer from '@/login/reducer'
//使用redux的combineReducers方法将所有reducer打包起来
const rootReducer = combineReducers({
    routing: routerReducer,//注意一定要加上routing: routerReducer 这是用于redux和react-router的连接
    app: appReducer,
    person: personReducer,
    suggest: suggestReducer,
    auth: loginReducer
})
export default rootReducer